#ifndef _OPERATOR_H_
#define _OPERATOR_H

#include <vector>
#include <string>

#include "Common.h"
#include "OperatorCost.h"

class Operator
{
private:
	std::string name;

	OperatorProperties properties;
	std::vector <Operator *> opsComm;
public:
	Operator(std::string name);

	std::string getName();

	OperatorProperties getOpProperties();
	void setOpProperties(OperatorProperties properties);

	void addCommOps(std::vector <Operator *> &opsComm);
	Operator *findCommOp(Operator *op);
};

struct OperatorNode
{
	Operator *op;
	Cost *cost;

	OperatorNode(Operator *op, Cost *cost = 0);
	~OperatorNode();
};

extern std::vector <Operator *> Operators;

#endif
